package com.ruoyi.pollutant.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.pollutant.mapper.OutletExhaustMapper;
import com.ruoyi.pollutant.domain.OutletExhaust;
import com.ruoyi.pollutant.service.IOutletExhaustService;

/**
 * 废气排放Service业务层处理
 * 
 * @author yxf
 * @date 2021-08-10
 */
@Service
public class OutletExhaustServiceImpl implements IOutletExhaustService 
{
    @Autowired
    private OutletExhaustMapper outletExhaustMapper;

    /**
     * 查询废气排放
     * 
     * @param exoId 废气排放ID
     * @return 废气排放
     */
    @Override
    public OutletExhaust selectOutletExhaustById(Long exoId)
    {
        return outletExhaustMapper.selectOutletExhaustById(exoId);
    }

    /**
     * 查询废气排放列表
     * 
     * @param outletExhaust 废气排放
     * @return 废气排放
     */
    @Override
    public List<OutletExhaust> selectOutletExhaustList(OutletExhaust outletExhaust)
    {
        return outletExhaustMapper.selectOutletExhaustList(outletExhaust);
    }

    /**
     * 新增废气排放
     * 
     * @param outletExhaust 废气排放
     * @return 结果
     */
    @Override
    public int insertOutletExhaust(OutletExhaust outletExhaust)
    {
        outletExhaust.setCreateTime(DateUtils.getNowDate());
        return outletExhaustMapper.insertOutletExhaust(outletExhaust);
    }

    /**
     * 修改废气排放
     * 
     * @param outletExhaust 废气排放
     * @return 结果
     */
    @Override
    public int updateOutletExhaust(OutletExhaust outletExhaust)
    {
        outletExhaust.setUpdateTime(DateUtils.getNowDate());
        return outletExhaustMapper.updateOutletExhaust(outletExhaust);
    }

    /**
     * 批量删除废气排放
     * 
     * @param exoIds 需要删除的废气排放ID
     * @return 结果
     */
    @Override
    public int deleteOutletExhaustByIds(Long[] exoIds)
    {
        return outletExhaustMapper.deleteOutletExhaustByIds(exoIds);
    }

    /**
     * 删除废气排放信息
     * 
     * @param exoId 废气排放ID
     * @return 结果
     */
    @Override
    public int deleteOutletExhaustById(Long exoId)
    {
        return outletExhaustMapper.deleteOutletExhaustById(exoId);
    }
}
